const app =getApp();
var util = require("../../utils/util.js");

var network = require("../../utils/Network.js");

Page({
    data: {
        // active: !1,
        // defaultCard: null,
        // balance: "",
        // notic: "",
        // indicatorDots: !1,
        // autoplay: !0,
        // interval: 5e3,
        // duration: 1500
        codestr:""
    },
    
    onLoad: function(a) {
        wx.showShareMenu({
            withShareTicket: !0
        });
        
    },
    onShow: function() {
        var a = this;
        const _self = this;
        // wx.showLoading({
        //     title: "请稍后"
        // }), getApp().data.authorization ? this.activeCard(getApp().data.authorization) : getApp().getAuthorizationCallback = function(t) {
        //     a.activeCard(t.data.obj.Authorization), wx.setStorageSync("authorization", t.data.obj.Authorization);
        // };
        wx.login({
            complete: function(a) {
                console.log(a)
                console.log(a.code)
                _self.setData({codestr : a.code});
            }
        });    
    }
    ,
    handleWarning: function(a) {
        $Message({
            content: a,
            type: "warning"
        });
    }
});